<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>repeat</title>
</head>
<body>
  <script>
    var str = 'x'.repeat(3);
    console.log(str);
    var str2 = 'hello'.repeat(3);
    console.log(str2);
  </script>
</body>
</html>